package com.probiz.estore.common.model.system.base;

import java.io.Serializable;
import java.util.HashMap;

import org.apache.commons.lang.builder.EqualsBuilder;
import org.apache.commons.lang.builder.HashCodeBuilder;
import org.apache.commons.lang.builder.ToStringBuilder;

import com.probiz.estore.common.model.system.PaymentGateway;

/**
 * PaymentGateway Base Java Bean, base class for the model, mapped directly to database table
 * 
 * Avoid changing this file if not necessary, will be overwritten. 
 *
 */
public class PaymentGatewayTbl extends com.probiz.estore.core.model.BaseObject implements Serializable {

    protected Integer paymentGatewayId;
	protected String paymentGatewayName;
	protected Short paymentGatewayType;
	protected String paymentGatewayDetail;
	protected String paymentGatewayCode;
	protected String processorFile;
	protected String configFile;
	protected HashMap configData;
	protected String gatewayIcon;
	protected Short isAdded;
	protected Integer sortOrder;
	protected Integer version;

	protected java.util.Set paymentMethods = new java.util.HashSet();

	/**
	 * Default Empty Constructor for class PaymentGateway
	 */
	public PaymentGatewayTbl () {
		super();
	}
	
	/**
	 * Default Key Fields Constructor for class PaymentGateway
	 */
	public PaymentGatewayTbl (
		 Integer in_paymentGatewayId
        ) {
		this.setPaymentGatewayId(in_paymentGatewayId);
    }


	public java.util.Set getPaymentMethods () {
		return paymentMethods;
	}	
	
	public void setPaymentMethods (java.util.Set in_paymentMethods) {
		this.paymentMethods = in_paymentMethods;
	}
    

	/**
	 * @return Integer
     * @hibernate.id column="paymentGatewayId" type="java.lang.Integer" generator-class="native"
	 */
	public Integer getPaymentGatewayId() {
		return this.paymentGatewayId;
	}
	
	/**
	 * Set the paymentGatewayId
	 */	
	public void setPaymentGatewayId(Integer aValue) {
		this.paymentGatewayId = aValue;
	}	

	/**
	 * @return String
	 * @hibernate.property column="paymentGatewayName" type="java.lang.String" length="256" not-null="false" unique="false"
	 */
	public String getPaymentGatewayName() {
		return this.paymentGatewayName;
	}
	
	/**
	 * Set the paymentGatewayName
	 */	
	public void setPaymentGatewayName(String aValue) {
		this.paymentGatewayName = aValue;
	}	
	
	/**
	 * @return Short
	 * @hibernate.property column="paymentGatewayType" type="java.lang.Short" length="5" not-null="false" unique="false"
	 */
	public Short getPaymentGatewayType() {
		return paymentGatewayType;
	}
	
	/**
	 * Set the paymentGatewayType
	 */	
	public void setPaymentGatewayType(Short paymentGatewayType) {
		this.paymentGatewayType = paymentGatewayType;
	}

	/**
	 * @return String
	 * @hibernate.property column="paymentGatewayDetail" type="java.lang.String" length="512" not-null="false" unique="false"
	 */
	public String getPaymentGatewayDetail() {
		return this.paymentGatewayDetail;
	}
	
	/**
	 * Set the paymentGatewayDetail
	 */	
	public void setPaymentGatewayDetail(String aValue) {
		this.paymentGatewayDetail = aValue;
	}	

	
    public String getPaymentGatewayCode() {
        return paymentGatewayCode;
    }
   
    public void setPaymentGatewayCode(String paymentGatewayCode) {
        this.paymentGatewayCode = paymentGatewayCode;
    }
   
	/**
	 * @return String
	 * @hibernate.property column="processorFile" type="java.lang.String" length="128" not-null="false" unique="false"
	 */
	public String getProcessorFile() {
		return this.processorFile;
	}
	
	/**
	 * Set the processorFile
	 */	
	public void setProcessorFile(String aValue) {
		this.processorFile = aValue;
	}	

	/**
	 * @return String
	 * @hibernate.property column="configFile" type="java.lang.String" length="128" not-null="false" unique="false"
	 */
	public String getConfigFile() {
		return this.configFile;
	}
	
	/**
	 * Set the configFile
	 */	
	public void setConfigFile(String aValue) {
		this.configFile = aValue;
	}	

	/**
	 * @return String
	 * @hibernate.property column="configData" type="java.lang.String" length="65535" not-null="false" unique="false"
	 */
	public HashMap getConfigData() {
		return this.configData;
	}
	
	/**
	 * Set the configData
	 */	
	public void setConfigData(HashMap aValue) {
		this.configData = aValue;
	}	

	/**
	 * @return String
	 * @hibernate.property column="gatewayIcon" type="java.lang.String" length="128" not-null="false" unique="false"
	 */
	public String getGatewayIcon() {
		return this.gatewayIcon;
	}
	
	/**
	 * Set the gatewayIcon
	 */	
	public void setGatewayIcon(String aValue) {
		this.gatewayIcon = aValue;
	}	

	/**
	 * @return Short
	 * @hibernate.property column="isAdded" type="java.lang.Short" length="6" not-null="false" unique="false"
	 */
	public Short getIsAdded() {
		return this.isAdded;
	}
	
	/**
	 * Set the isAdded
	 */	
	public void setIsAdded(Short aValue) {
		this.isAdded = aValue;
	}	
	

	
	public Integer getSortOrder() {
		return sortOrder;
	}

	public void setSortOrder(Integer sortOrder) {
		this.sortOrder = sortOrder;
	}

	/**
	 * @return Integer
	 * @hibernate.property column="version" type="java.lang.Integer" length="11" not-null="false" unique="false"
	 */
	public Integer getVersion() {
		return this.version;
	}
	
	/**
	 * Set the version
	 */	
	public void setVersion(Integer aValue) {
		this.version = aValue;
	}	

	/**
	 * @see java.lang.Object#equals(Object)
	 */
	public boolean equals(Object object) {
		if (!(object instanceof PaymentGateway)) {
			return false;
		}
		PaymentGateway rhs = (PaymentGateway) object;
		return new EqualsBuilder()
				.append(this.paymentGatewayId, rhs.paymentGatewayId)
				.append(this.paymentGatewayName, rhs.paymentGatewayName)
				.append(this.paymentGatewayType, rhs.paymentGatewayType)
				.append(this.paymentGatewayDetail, rhs.paymentGatewayDetail)
				.append(this.processorFile, rhs.processorFile)
				.append(this.configFile, rhs.configFile)
				.append(this.configData, rhs.configData)
				.append(this.gatewayIcon, rhs.gatewayIcon)
				.append(this.isAdded, rhs.isAdded)
				.append(this.version, rhs.version)
				.isEquals();
	}

	/**
	 * @see java.lang.Object#hashCode()
	 */
	public int hashCode() {
		return new HashCodeBuilder(-82280557, -700257973)
				.append(this.paymentGatewayId) 
				.append(this.paymentGatewayName) 
				.append(this.paymentGatewayType)
				.append(this.paymentGatewayDetail) 
				.append(this.processorFile) 
				.append(this.configFile) 
				.append(this.configData) 
				.append(this.gatewayIcon) 
				.append(this.isAdded) 
				.append(this.version) 
				.toHashCode();
	}

	/**
	 * @see java.lang.Object#toString()
	 */
	public String toString() {
		return new ToStringBuilder(this)
				.append("paymentGatewayId", this.paymentGatewayId) 
				.append("paymentGatewayName", this.paymentGatewayName) 
				.append("paymentGatewayType", this.paymentGatewayType)
				.append("paymentGatewayDetail", this.paymentGatewayDetail) 
				.append("processorFile", this.processorFile) 
				.append("configFile", this.configFile) 
				.append("configData", this.configData) 
				.append("gatewayIcon", this.gatewayIcon) 
				.append("isAdded", this.isAdded) 
				.append("version", this.version) 
				.toString();
	}

	/**
	 * Return the name of the first key column
	 */
	public String getFirstKeyColumnName() {
		return "paymentGatewayId";
	}
	
}